<html>
 <head>
  <link href="./leetcode-problem.css" rel="stylesheet" type="text/css">
 </head>
 <body>
  <div class="question_difficulty">
   难度：Easy
  </div>
  <div>
   <h1 class="question_title">
    898. Transpose Matrix
   </h1>
   <p>
    Given a&nbsp;matrix
    <code>
     A
    </code>
    , return the transpose of
    <code>
     A
    </code>
    .
   </p>
   <p>
    The transpose of a matrix is the matrix flipped over it's main diagonal, switching the row and column indices of the matrix.
   </p>
   <p>
    &nbsp;
   </p>
   <div>
    <p>
     <strong>
      Example 1:
     </strong>
    </p>
    <pre>
<strong>Input: </strong><span id="example-input-1-1">[[1,2,3],[4,5,6],[7,8,9]]</span>
<strong>Output: </strong><span id="example-output-1">[[1,4,7],[2,5,8],[3,6,9]]</span>
</pre>
    <div>
     <p>
      <strong>
       Example 2:
      </strong>
     </p>
     <pre>
<strong>Input: </strong><span id="example-input-2-1">[[1,2,3],[4,5,6]]</span>
<strong>Output: </strong><span id="example-output-2">[[1,4],[2,5],[3,6]]</span>
</pre>
     <p>
      &nbsp;
     </p>
     <p>
      <span>
       <strong>
        Note:
       </strong>
      </span>
     </p>
     <ol>
      <li>
       <code>
        <span>
         1 &lt;= A.length&nbsp;&lt;= 1000
        </span>
       </code>
      </li>
      <li>
       <code>
        <span>
         1 &lt;= A[0].length&nbsp;&lt;= 1000
        </span>
       </code>
      </li>
     </ol>
    </div>
   </div>
  </div>
  <div>
   <h1 class="question_title">
    898. 转置矩阵
   </h1>
   <p>
    给定一个矩阵&nbsp;
    <code>
     A
    </code>
    ，&nbsp;返回&nbsp;
    <code>
     A
    </code>
    &nbsp;的转置矩阵。
   </p>
   <p>
    矩阵的转置是指将矩阵的主对角线翻转，交换矩阵的行索引与列索引。
   </p>
   <p>
    &nbsp;
   </p>
   <p>
    <strong>
     示例 1：
    </strong>
   </p>
   <pre><strong>输入：</strong>[[1,2,3],[4,5,6],[7,8,9]]
<strong>输出：</strong>[[1,4,7],[2,5,8],[3,6,9]]
</pre>
   <p>
    <strong>
     示例 2：
    </strong>
   </p>
   <pre><strong>输入：</strong>[[1,2,3],[4,5,6]]
<strong>输出：</strong>[[1,4],[2,5],[3,6]]
</pre>
   <p>
    &nbsp;
   </p>
   <p>
    <strong>
     提示：
    </strong>
   </p>
   <ol>
    <li>
     <code>
      1 &lt;= A.length&nbsp;&lt;= 1000
     </code>
    </li>
    <li>
     <code>
      1 &lt;= A[0].length&nbsp;&lt;= 1000
     </code>
    </li>
   </ol>
  </div>
 </body>
</html>